Best way to block "comment spam" postings to web forms? [closed]

Posted by David Jones on Pro Webmasters See other posts from Pro Webmasters or by David Jones
Published on 2011-02-28T04:25:53Z Indexed on 2011/02/28 15:33 UTC
Read the original article Hit count: 374

Filed under:

Possible Duplicate:
Make your site anti-bot?

I have a custom web form on my PHP-based site.

Recently it is getting a regular stream of comment-spam postings from a few specific IP addresses.

Question: What is a good way to block a small set of blacklisted IP addresses from accessing my site?

I was thinking it should be possible using .htaccess to respond with status code 403 (Forbidden) for all HTTP requests from the blacklisted IP addresses, ... but I am not sure exactly how to do that.

If anyone knows the .htaccess syntax needed to accomplish this, ... please let me know.

thanks in advance,

© Pro Webmasters or respective owner

Related posts about spam-prevention